import Vue from 'vue'
import Router from 'vue-router'
import Hello from '../index'
// import Login from '../login'
let Login = resolve => {
  require(['../login'], resolve)
}
let controller = resolve => require(['../controller'], resolve)
let baseSysLog = resolve => require(['../../../components/base/baseSysLog'], resolve)
let baseNotice = resolve => require(['../../../components/base/baseNotice'], resolve)
let baseRole = resolve => require(['../../../components/base/baseRole'], resolve)
let baseDept = resolve => require(['../../../components/base/baseDept'], resolve)
let baseMenu = resolve => require(['../../../components/base/baseMenu'], resolve)
let baseAccount = resolve => require(['../../../components/base/baseAccount'], resolve)
let basePicStore = resolve => require(['../../../components/base/basePicStore'], resolve)
let adminAccountblk = resolve => require(['../../../components/base/adminAccountblk'], resolve)
let product = resolve => require(['../../../components/product/product'], resolve)
let menuControl = resolve => require(['../../../components/base/menuControl'], resolve)
let baseNoticeAdd = resolve => require(['../../../components/base/baseNoticeAdd'], resolve)
let baseLoginInfo = resolve => require(['../../../components/base/baseLoginInfo'], resolve)
let indexManage = resolve => require(['../../../components/base/indexManage'], resolve)
let productFeatures = resolve => require(['../../../components/product/productFeatures'], resolve)
let productManageList = resolve => require(['../../../components/product/productManageList'], resolve)
let auditsProduct = resolve => require(['../../../components/product/auditsProduct'], resolve)
let merchantMessage = resolve => require(['../../../components/base/merchantMessage.vue'], resolve)
let retailGoods = resolve => require(['../../../components/retail/retailGoods.vue'], resolve)
let retailGoodsAdd = resolve => require(['../../../components/retail/retailGoodsAdd.vue'], resolve)
let baseGoodsDetails = resolve => require(['../../../components/base/baseGoodsDetails.vue'], resolve)
let memberManage = resolve => require(['../../../components/base/memberManage.vue'], resolve)
let survey = resolve => require(['../../../components/base/survey'], resolve)
let Page404 = resolve => require(['../404'], resolve)
let mongoLogs = resolve => require(['../../../components/base/mongoLogs.vue'], resolve)
let retailGoodsGroup = resolve => require(['../../../components/retail/retailGoodsGroup.vue'], resolve)
let retailShopConfig = resolve => require(['../../../components/base/retailShopConfig'], resolve)
let feedbackList = resolve => require(['../../../components/base/feedbackList'], resolve)
let exceptionReportList = resolve => require(['../../../components/base/exceptionReportList'], resolve)
let streetLamp = resolve => require(['../../../components/base/streetLamp'], resolve)
let streetLampChange = resolve => require(['../../../components/base/streetLampChange'], resolve)
let openRemind = resolve => require(['../../../components/base/openRemind'], resolve)
let pdBox = resolve => require(['../../../components/base/pdBox'], resolve)
let map = resolve => require(['../../../components/base/map'], resolve)
let pdBoxDetail = resolve => require(['../../../components/base/pdBoxDetail'], resolve)
let pdBoxChange = resolve => require(['../../../components/base/pdBoxChange'], resolve)
let road = resolve => require(['../../../components/base/road'], resolve)
let team = resolve => require(['../../../components/base/team'], resolve)
let processed = resolve => require(['../../../components/base/processed'], resolve)
let workRecord = resolve => require(['../../../components/base/workRecord'], resolve)
Vue.use(Router)
export default new Router({
  'linkActiveClass': 'active',
  mode: 'history',
  routes: [
    {
      path: '/',
      name: '',
      component: Hello,
      leaf: true,
      children: [
        {path: '/baseSysLog', name: '系统日志', component: baseSysLog},
        {path: '/baseNotice', name: '消息管理', component: baseNotice},
        {path: '/baseRole', name: '角色管理', component: baseRole},
        {path: '/baseDept', name: '部门管理', component: baseDept},
        {path: '/baseMenu', name: '权限管理', component: baseMenu},
        {path: '/baseAccount', name: 'baseAccount', component: baseAccount},
        {path: '/basePicStore', name: '', component: basePicStore},
        {path: '/adminAccountblk', name: '账号管理', component: adminAccountblk},
        {path: '/product', name: 'productAll', component: product},
        {path: '/menuControl', name: 'menuControl', component: menuControl},
        {path: '/baseNoticeAdd', name: 'baseNoticeAdd', component: baseNoticeAdd},
        {path: '/baseLoginInfo', name: 'baseLoginInfo', component: baseLoginInfo},
        {path: '/indexManage', name: 'indexManage', component: indexManage},
        {path: '/productFeatures', name: 'productFeatures', component: productFeatures},
        {path: '/productManageList', name: 'productManageList', component: productManageList},
        {path: '/auditsProduct', name: 'auditsProduct', component: auditsProduct},
        {path: '/merchantMessage', name: 'merchantMessage', component: merchantMessage},
        {path: '/retailGoods', name: 'retailGoods', component: retailGoods},
        {path: '/retailGoodsAdd', name: 'retailGoodsAdd', component: retailGoodsAdd},
        {path: '/baseGoodsDetails/:orderNo', name: 'baseGoodsDetails', component: baseGoodsDetails},
        {path: '/memberManage', name: 'memberManage', component: memberManage},
        {path: '/mongoLogs', name: 'mongoLogs', component: mongoLogs},
        {path: '/survey', name: 'survey', component: survey},
        {path: '/retailGoodsGroup', name: 'retailGoodsGroup', component: retailGoodsGroup},
        {path: '/retailShopConfig', name: 'retailShopConfig', component: retailShopConfig},
        {path: '/feedbackList', name: 'feedbackList', component: feedbackList},
        {path: '/exceptionReportList', name: 'exceptionReportList', component: exceptionReportList},
        {path: '/streetLamp', name: 'streetLamp', component: streetLamp},
        {path: '/streetLampChange', name: 'streetLampChange', component: streetLampChange},
        {path: '/openRemind', name: 'openRemind', component: openRemind},
        {path: '/pdBox', name: 'pdBox', component: pdBox},
        {path: '/map', name: 'map', component: map},
        {path: '/pdBoxDetail', name: 'pdBoxDetail', component: pdBoxDetail},
        {path: '/pdBoxChange', name: 'pdBoxChange', component: pdBoxChange},
        {path: '/road', name: 'road', component: road},
        {path: '/team', name: 'team', component: team},
        {path: '/processed', name: 'processed', component: processed},
        {path: '/workRecord', name: 'workRecord', component: workRecord}
      ]
    },
    {
      path: '/login',
      component: Login,
      name: '',
      hidden: true
    },
    {
      path: '/controller',
      component: controller,
      name: 'controller',
      hidden: true
    },
    {
      path: '*',
      component: Page404,
      name: ''
    }
    // {
    //   path: '/',
    //   name: '账号管理',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/customAccount', name: '账号列表', component: baseAccount},
    //     {path: '/baseAccount', name: '账号列表1', component: adminAccountblk}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '公司管理',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseCompany', name: '公司列表', component: baseCompany}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '菜单管理',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseMenu', name: '菜单列表', component: baseMenu}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '问题反馈',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseFeedback', name: '反馈列表', component: baseFeedback}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '新增反馈',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseFeedbackAdd/:id/:ftype', name: '新增反馈', component: baseFeedbackAdd},
    //     {path: '/baseFeedbackAdd', name: '新增反馈1', component: baseFeedbackAdd}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '问题反馈回复',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseFeedbackReply/:id/:ftype', name: '反馈回复', component: baseFeedbackReply},
    //     {path: '/baseFeedbackReply', name: '反馈回复1', component: baseFeedbackReply}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '公告查询',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseNotice', name: '系统公告', component: baseNotice}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '日志查询',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseSysLog', name: '日志列表', component: baseSysLog}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '发布公告',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/addNotice', name: '发布公告1', component: addNotice},
    //     {path: '/addNotice/:id/:pageType', name: '发布公告', component: addNotice}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '系统配置',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseConfig', name: '系统配置', component: baseConfig}
    //   ]
    // },
    // {
    //   path: '/',
    //   name: '常见问题',
    //   component: Hello,
    //   leaf: true,
    //   children: [
    //     {path: '/baseQuestion', name: '常见问题', component: baseQuestion}
    //   ]
    // }
  ]
})
